package com.cangxuan.manage.dao;

import com.cangxuan.manage.entity.Article;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 文章DAO
 * Author:罗健
 */
@Mapper
public interface IArticleDao {
    List<Article> selectArticleByTypeId(@Param("pageIndex") int pageIndex,
                       @Param("pageSize") int pageSize,
                       @Param("typeId") int typeId,
                       @Param("title") String title);
    int selectCount(@Param("title") String title, @Param("typeId") int typeId);
    int insertArticle(Article article);

    int up(Article article);

    int deleteArticle(int id);

}
